using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MageDefender.GameClasses
{
    public class Castle
    {
        bool isCurrentWaveABoss;

        public bool IsCurrentWaveABoss
        {
            get { return isCurrentWaveABoss; }
            set { isCurrentWaveABoss = value; }
        }

        int hp;

        public int Hp
        {
            get {
                if (Level <= 0)
                {
                    hp = 0;
                }
                else hp = 10000;
                return hp; 
            }
            set { hp = value; }
        }
        int wave;

        public int Wave
        {
            get { return wave; }
            set { wave = value; }
        }
        int level;

        public int Level
        {
            get { return level; }
            set { level = value; }
        }

        int enemiesInCurrentWave;

        public int EnemiesInCurrentWave
        {
            get { return enemiesInCurrentWave; }
            set { enemiesInCurrentWave = value; }
        }

        bool waveEnded;

        public bool WaveEnded
        {
            get { return waveEnded; }
            set { waveEnded = value; }
        }

        float defence;

        public float Defence
        {
            get { return defence; }
            set { defence = value; }
        }

        public Castle()
        {
            level = 2; // Level on current castle
            wave = 0; // current wave
            enemiesInCurrentWave = 15; // enemies to spawn in wave
            Hp = 2; // Hp left of castle, 0 = game over
            defence = 1; // castles overal defence level
            isCurrentWaveABoss = false;
        }
    }
}